<?php
return array(
	'basePath'=>dirname(__FILE__).DIRECTORY_SEPARATOR.'..',
	'name'=>'CROSSOVER TV',
	'preload'=>array('log'), // Enable Logs
	'import'=>array( // Autoloading model and component classes
		'application.models.*',
		'application.components.*',
	),

	'modules'=>array( // Enable Gii Tools
		'gii'=>array(
			'class'=>'system.gii.GiiModule',
			'password'=>'sarawan2!',
		),
	),

	'components'=>array( // application components
		'user'=>array( // enable cookie-based authentication
			'allowAutoLogin'=>true,
		),
			
		'urlManager'=>array(
			'urlFormat'=>'path',
			'showScriptName'=>false,
			'rules'=>array(
				'<controller:\w+>/<id:\d+>'=>'<controller>/view',
				'<controller:\w+>/<action:\w+>/<id:\d+>'=>'<controller>/<action>',
				'<controller:\w+>/<action:\w+>'=>'<controller>/<action>',
				'<controller:\w+>/<id:\d+>/<title>'=>'<controller>/view',
				'login' => 'site/login',
			),
		),
		
		'db'=>array(
			'connectionString' => 'mysql:host=localhost;dbname=xov',
			'emulatePrepare' => true,
			'username' => 'root',
			'password' => 'root',
			'charset' => 'utf8',
		),
		
		'errorHandler'=>array(
			// use 'site/error' action to display errors
      'errorAction'=>'site/error',
    ),
		'log'=>array(
			'class'=>'CLogRouter',
			'routes'=>array(
				array(
					'class'=>'CFileLogRoute',
					'levels'=>'error, warning',
				),
			),
		),
	),

	'params'=>array(
		'adminEmail'=>'webmaster@cloverink.com',
	),
);